using System;
using System.Collections.Generic;
using System.Text;
using Shc.Sql;
using Shc.Json;
namespace Slqj.Data
{
	public static class TableViewGuestRoomStatus
	{
		public const string Table = "View_GuestRoomStatus";
		public const string GuestRoomStatusID = "GuestRoomStatusID";
		public const string RoomStatusID = "RoomStatusID";
		public const string StartDate = "StartDate";
		public const string EndDate = "EndDate";
		public const string Creater = "Creater";
		public const string CreatedBy = "CreatedBy";
		public const string Created = "Created";
		public const string Modified = "Modified";
		public const string ModifiedBy = "ModifiedBy";
		public const string ModifiedByID = "ModifiedByID";
		public const string GuestRoomIDList = "GuestRoomIDList";
		public const string RoomStatusName = "RoomStatusName";
	}
	
	[Serializable]
	public class BaseViewGuestRoomStatus
		: IDbSessionEntity, IJsonClass
	{
		int m_GuestRoomStatusID;
		/// <summary>
        /// 
        /// </summary>
        public int GuestRoomStatusID
        {
            get { return m_GuestRoomStatusID; }
            set { m_GuestRoomStatusID = value; }
        }
		
		int? m_RoomStatusID;
		/// <summary>
        /// 
        /// </summary>
        public int? RoomStatusID
        {
            get { return m_RoomStatusID; }
            set { m_RoomStatusID = value; }
        }
		
		DateTime m_StartDate;
		/// <summary>
        /// 
        /// </summary>
        public DateTime StartDate
        {
            get { return m_StartDate; }
            set { m_StartDate = value; }
        }
		
		DateTime m_EndDate;
		/// <summary>
        /// 
        /// </summary>
        public DateTime EndDate
        {
            get { return m_EndDate; }
            set { m_EndDate = value; }
        }
		
		int m_Creater;
		/// <summary>
        /// 
        /// </summary>
        public int Creater
        {
            get { return m_Creater; }
            set { m_Creater = value; }
        }
		
		string m_CreatedBy;
		/// <summary>
        /// 
        /// </summary>
        public string CreatedBy
        {
            get { return m_CreatedBy; }
            set { m_CreatedBy = value; }
        }
		
		DateTime m_Created;
		/// <summary>
        /// 
        /// </summary>
        public DateTime Created
        {
            get { return m_Created; }
            set { m_Created = value; }
        }
		
		DateTime m_Modified;
		/// <summary>
        /// 
        /// </summary>
        public DateTime Modified
        {
            get { return m_Modified; }
            set { m_Modified = value; }
        }
		
		string m_ModifiedBy;
		/// <summary>
        /// 
        /// </summary>
        public string ModifiedBy
        {
            get { return m_ModifiedBy; }
            set { m_ModifiedBy = value; }
        }
		
		int? m_ModifiedByID;
		/// <summary>
        /// 
        /// </summary>
        public int? ModifiedByID
        {
            get { return m_ModifiedByID; }
            set { m_ModifiedByID = value; }
        }
		
		string m_GuestRoomIDList;
		/// <summary>
        /// 
        /// </summary>
        public string GuestRoomIDList
        {
            get { return m_GuestRoomIDList; }
            set { m_GuestRoomIDList = value; }
        }
		
		string m_RoomStatusName;
		/// <summary>
        /// 
        /// </summary>
        public string RoomStatusName
        {
            get { return m_RoomStatusName; }
            set { m_RoomStatusName = value; }
        }
		
		
		#region IDbSessionEntity Members
		public void ReadDBData(RowDataReader reader)
        {
            m_GuestRoomStatusID = reader[TableViewGuestRoomStatus.GuestRoomStatusID];
            m_RoomStatusID = reader[TableViewGuestRoomStatus.RoomStatusID];
            m_StartDate = reader[TableViewGuestRoomStatus.StartDate];
            m_EndDate = reader[TableViewGuestRoomStatus.EndDate];
            m_Creater = reader[TableViewGuestRoomStatus.Creater];
            m_CreatedBy = reader[TableViewGuestRoomStatus.CreatedBy];
            m_Created = reader[TableViewGuestRoomStatus.Created];
            m_Modified = reader[TableViewGuestRoomStatus.Modified];
            m_ModifiedBy = reader[TableViewGuestRoomStatus.ModifiedBy];
            m_ModifiedByID = reader[TableViewGuestRoomStatus.ModifiedByID];
            m_GuestRoomIDList = reader[TableViewGuestRoomStatus.GuestRoomIDList];
            m_RoomStatusName = reader[TableViewGuestRoomStatus.RoomStatusName];
        }
		
		public void WriteDBData(RowDataWriter writer)
        {
        }

        public void SetIdentityAfterInsert(DBObject idd)
        {
        }
		
		public string TableName
        {
            get { return TableViewGuestRoomStatus.Table; }
        }
		#endregion
		
		
		#region IJsonClass Members

        public void JsonDeSerializeObj(JsonHashTable hashToRead)
        {
             m_GuestRoomStatusID = hashToRead["GuestRoomStatusID"];
			 
             m_RoomStatusID = hashToRead["RoomStatusID"];
			 
             m_StartDate = hashToRead["StartDate"];
			 
             m_EndDate = hashToRead["EndDate"];
			 
             m_Creater = hashToRead["Creater"];
			 
             m_CreatedBy = hashToRead["CreatedBy"];
			 
             m_Created = hashToRead["Created"];
			 
             m_Modified = hashToRead["Modified"];
			 
             m_ModifiedBy = hashToRead["ModifiedBy"];
			 
             m_ModifiedByID = hashToRead["ModifiedByID"];
			 
             m_GuestRoomIDList = hashToRead["GuestRoomIDList"];
			 
             m_RoomStatusName = hashToRead["RoomStatusName"];
			 
        }

        public void JsonSerializeObj(JsonHashTable hashToFill)
        {
            hashToFill["GuestRoomStatusID"] = GuestRoomStatusID;
			
            hashToFill["RoomStatusID"] = RoomStatusID;
			
            hashToFill["StartDate"] = StartDate;
			
            hashToFill["EndDate"] = EndDate;
			
            hashToFill["Creater"] = Creater;
			
            hashToFill["CreatedBy"] = CreatedBy;
			
            hashToFill["Created"] = Created;
			
            hashToFill["Modified"] = Modified;
			
            hashToFill["ModifiedBy"] = ModifiedBy;
			
            hashToFill["ModifiedByID"] = ModifiedByID;
			
            hashToFill["GuestRoomIDList"] = GuestRoomIDList;
			
            hashToFill["RoomStatusName"] = RoomStatusName;
			
        }

        #endregion
		
	}
}
